Optimal. Leaf size=156 \[ \frac {93 a^5 \tanh ^{-1}(\sin (c+d x))}{16 d}+\frac {16 a^5 \tan (c+d x)}{d}+\frac {93 a^5 \sec (c+d x) \tan (c+d x)}{16 d}+\frac {85 a^5 \sec ^3(c+d x) \tan (c+d x)}{24 d}+\frac {5 a^5 \sec ^5(c+d x) \tan (c+d x)}{6 d}+\frac {28 a^5 \tan ^3(c+d x)}{3 d}+\frac {13 a^5 \tan ^5(c+d x)}{5 d}+\frac {a^5 \tan ^7(c+d x)}{7 d} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.15, antiderivative size = 156, normalized size of antiderivative = 1.00, number of steps
used = 17, number of rules used = 4, integrand size = 21, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.190, Rules used = {3876, 3853,
3855, 3852} \begin {gather*} \frac {a^5 \tan ^7(c+d x)}{7 d}+\frac {13 a^5 \tan ^5(c+d x)}{5 d}+\frac {28 a^5 \tan ^3(c+d x)}{3 d}+\frac {16 a^5 \tan (c+d x)}{d}+\frac {93 a^5 \tanh ^{-1}(\sin (c+d x))}{16 d}+\frac {5 a^5 \tan (c+d x) \sec ^5(c+d x)}{6 d}+\frac {85 a^5 \tan (c+d x) \sec ^3(c+d x)}{24 d}+\frac {93 a^5 \tan (c+d x) \sec (c+d x)}{16 d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 3852
Rule 3853
Rule 3855
Rule 3876
Rubi steps
\begin {align*} \int \sec ^3(c+d x) (a+a \sec (c+d x))^5 \, dx &=\int \left (a^5 \sec ^3(c+d x)+5 a^5 \sec ^4(c+d x)+10 a^5 \sec ^5(c+d x)+10 a^5 \sec ^6(c+d x)+5 a^5 \sec ^7(c+d x)+a^5 \sec ^8(c+d x)\right ) \, dx\\ &=a^5 \int \sec ^3(c+d x) \, dx+a^5 \int \sec ^8(c+d x) \, dx+\left (5 a^5\right ) \int \sec ^4(c+d x) \, dx+\left (5 a^5\right ) \int \sec ^7(c+d x) \, dx+\left (10 a^5\right ) \int \sec ^5(c+d x) \, dx+\left (10 a^5\right ) \int \sec ^6(c+d x) \, dx\\ &=\frac {a^5 \sec (c+d x) \tan (c+d x)}{2 d}+\frac {5 a^5 \sec ^3(c+d x) \tan (c+d x)}{2 d}+\frac {5 a^5 \sec ^5(c+d x) \tan (c+d x)}{6 d}+\frac {1}{2} a^5 \int \sec (c+d x) \, dx+\frac {1}{6} \left (25 a^5\right ) \int \sec ^5(c+d x) \, dx+\frac {1}{2} \left (15 a^5\right ) \int \sec ^3(c+d x) \, dx-\frac {a^5 \text {Subst}\left (\int \left (1+3 x^2+3 x^4+x^6\right ) \, dx,x,-\tan (c+d x)\right )}{d}-\frac {\left (5 a^5\right ) \text {Subst}\left (\int \left (1+x^2\right ) \, dx,x,-\tan (c+d x)\right )}{d}-\frac {\left (10 a^5\right ) \text {Subst}\left (\int \left (1+2 x^2+x^4\right ) \, dx,x,-\tan (c+d x)\right )}{d}\\ &=\frac {a^5 \tanh ^{-1}(\sin (c+d x))}{2 d}+\frac {16 a^5 \tan (c+d x)}{d}+\frac {17 a^5 \sec (c+d x) \tan (c+d x)}{4 d}+\frac {85 a^5 \sec ^3(c+d x) \tan (c+d x)}{24 d}+\frac {5 a^5 \sec ^5(c+d x) \tan (c+d x)}{6 d}+\frac {28 a^5 \tan ^3(c+d x)}{3 d}+\frac {13 a^5 \tan ^5(c+d x)}{5 d}+\frac {a^5 \tan ^7(c+d x)}{7 d}+\frac {1}{8} \left (25 a^5\right ) \int \sec ^3(c+d x) \, dx+\frac {1}{4} \left (15 a^5\right ) \int \sec (c+d x) \, dx\\ &=\frac {17 a^5 \tanh ^{-1}(\sin (c+d x))}{4 d}+\frac {16 a^5 \tan (c+d x)}{d}+\frac {93 a^5 \sec (c+d x) \tan (c+d x)}{16 d}+\frac {85 a^5 \sec ^3(c+d x) \tan (c+d x)}{24 d}+\frac {5 a^5 \sec ^5(c+d x) \tan (c+d x)}{6 d}+\frac {28 a^5 \tan ^3(c+d x)}{3 d}+\frac {13 a^5 \tan ^5(c+d x)}{5 d}+\frac {a^5 \tan ^7(c+d x)}{7 d}+\frac {1}{16} \left (25 a^5\right ) \int \sec (c+d x) \, dx\\ &=\frac {93 a^5 \tanh ^{-1}(\sin (c+d x))}{16 d}+\frac {16 a^5 \tan (c+d x)}{d}+\frac {93 a^5 \sec (c+d x) \tan (c+d x)}{16 d}+\frac {85 a^5 \sec ^3(c+d x) \tan (c+d x)}{24 d}+\frac {5 a^5 \sec ^5(c+d x) \tan (c+d x)}{6 d}+\frac {28 a^5 \tan ^3(c+d x)}{3 d}+\frac {13 a^5 \tan ^5(c+d x)}{5 d}+\frac {a^5 \tan ^7(c+d x)}{7 d}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 1.29, size = 229, normalized size = 1.47 \begin {gather*} -\frac {a^5 (1+\cos (c+d x))^5 \sec ^{10}\left (\frac {1}{2} (c+d x)\right ) \sec ^7(c+d x) \left (624960 \cos ^7(c+d x) \left (\log \left (\cos \left (\frac {1}{2} (c+d x)\right )-\sin \left (\frac {1}{2} (c+d x)\right )\right )-\log \left (\cos \left (\frac {1}{2} (c+d x)\right )+\sin \left (\frac {1}{2} (c+d x)\right )\right )\right )-\sec (c) (374080 \sin (d x)-162400 \sin (2 c+d x)+118825 \sin (c+2 d x)+118825 \sin (3 c+2 d x)+305088 \sin (2 c+3 d x)-16800 \sin (4 c+3 d x)+62860 \sin (3 c+4 d x)+62860 \sin (5 c+4 d x)+107296 \sin (4 c+5 d x)+9765 \sin (5 c+6 d x)+9765 \sin (7 c+6 d x)+15328 \sin (6 c+7 d x))\right )}{3440640 d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.15, size = 248, normalized size = 1.59
method | result | size |
risch | \(-\frac {i a^{5} \left (9765 \,{\mathrm e}^{13 i \left (d x +c \right )}+62860 \,{\mathrm e}^{11 i \left (d x +c \right )}-16800 \,{\mathrm e}^{10 i \left (d x +c \right )}+118825 \,{\mathrm e}^{9 i \left (d x +c \right )}-162400 \,{\mathrm e}^{8 i \left (d x +c \right )}-374080 \,{\mathrm e}^{6 i \left (d x +c \right )}-118825 \,{\mathrm e}^{5 i \left (d x +c \right )}-305088 \,{\mathrm e}^{4 i \left (d x +c \right )}-62860 \,{\mathrm e}^{3 i \left (d x +c \right )}-107296 \,{\mathrm e}^{2 i \left (d x +c \right )}-9765 \,{\mathrm e}^{i \left (d x +c \right )}-15328\right )}{840 d \left ({\mathrm e}^{2 i \left (d x +c \right )}+1\right )^{7}}+\frac {93 a^{5} \ln \left ({\mathrm e}^{i \left (d x +c \right )}+i\right )}{16 d}-\frac {93 a^{5} \ln \left ({\mathrm e}^{i \left (d x +c \right )}-i\right )}{16 d}\) | \(189\) |
norman | \(\frac {-\frac {419 a^{5} \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{8 d}+\frac {943 a^{5} \left (\tan ^{3}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{6 d}-\frac {37169 a^{5} \left (\tan ^{5}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{120 d}+\frac {11904 a^{5} \left (\tan ^{7}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{35 d}-\frac {8773 a^{5} \left (\tan ^{9}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{40 d}+\frac {155 a^{5} \left (\tan ^{11}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{2 d}-\frac {93 a^{5} \left (\tan ^{13}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{8 d}}{\left (\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )^{7}}-\frac {93 a^{5} \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )}{16 d}+\frac {93 a^{5} \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )+1\right )}{16 d}\) | \(190\) |
derivativedivides | \(\frac {-a^{5} \left (-\frac {16}{35}-\frac {\left (\sec ^{6}\left (d x +c \right )\right )}{7}-\frac {6 \left (\sec ^{4}\left (d x +c \right )\right )}{35}-\frac {8 \left (\sec ^{2}\left (d x +c \right )\right )}{35}\right ) \tan \left (d x +c \right )+5 a^{5} \left (-\left (-\frac {\left (\sec ^{5}\left (d x +c \right )\right )}{6}-\frac {5 \left (\sec ^{3}\left (d x +c \right )\right )}{24}-\frac {5 \sec \left (d x +c \right )}{16}\right ) \tan \left (d x +c \right )+\frac {5 \ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )}{16}\right )-10 a^{5} \left (-\frac {8}{15}-\frac {\left (\sec ^{4}\left (d x +c \right )\right )}{5}-\frac {4 \left (\sec ^{2}\left (d x +c \right )\right )}{15}\right ) \tan \left (d x +c \right )+10 a^{5} \left (-\left (-\frac {\left (\sec ^{3}\left (d x +c \right )\right )}{4}-\frac {3 \sec \left (d x +c \right )}{8}\right ) \tan \left (d x +c \right )+\frac {3 \ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )}{8}\right )-5 a^{5} \left (-\frac {2}{3}-\frac {\left (\sec ^{2}\left (d x +c \right )\right )}{3}\right ) \tan \left (d x +c \right )+a^{5} \left (\frac {\sec \left (d x +c \right ) \tan \left (d x +c \right )}{2}+\frac {\ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )}{2}\right )}{d}\) | \(248\) |
default | \(\frac {-a^{5} \left (-\frac {16}{35}-\frac {\left (\sec ^{6}\left (d x +c \right )\right )}{7}-\frac {6 \left (\sec ^{4}\left (d x +c \right )\right )}{35}-\frac {8 \left (\sec ^{2}\left (d x +c \right )\right )}{35}\right ) \tan \left (d x +c \right )+5 a^{5} \left (-\left (-\frac {\left (\sec ^{5}\left (d x +c \right )\right )}{6}-\frac {5 \left (\sec ^{3}\left (d x +c \right )\right )}{24}-\frac {5 \sec \left (d x +c \right )}{16}\right ) \tan \left (d x +c \right )+\frac {5 \ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )}{16}\right )-10 a^{5} \left (-\frac {8}{15}-\frac {\left (\sec ^{4}\left (d x +c \right )\right )}{5}-\frac {4 \left (\sec ^{2}\left (d x +c \right )\right )}{15}\right ) \tan \left (d x +c \right )+10 a^{5} \left (-\left (-\frac {\left (\sec ^{3}\left (d x +c \right )\right )}{4}-\frac {3 \sec \left (d x +c \right )}{8}\right ) \tan \left (d x +c \right )+\frac {3 \ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )}{8}\right )-5 a^{5} \left (-\frac {2}{3}-\frac {\left (\sec ^{2}\left (d x +c \right )\right )}{3}\right ) \tan \left (d x +c \right )+a^{5} \left (\frac {\sec \left (d x +c \right ) \tan \left (d x +c \right )}{2}+\frac {\ln \left (\sec \left (d x +c \right )+\tan \left (d x +c \right )\right )}{2}\right )}{d}\) | \(248\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [B] Leaf count of result is larger than twice the leaf count of optimal. 314 vs.
\(2 (142) = 284\).
time = 0.29, size = 314, normalized size = 2.01 \begin {gather*} \frac {96 \, {\left (5 \, \tan \left (d x + c\right )^{7} + 21 \, \tan \left (d x + c\right )^{5} + 35 \, \tan \left (d x + c\right )^{3} + 35 \, \tan \left (d x + c\right )\right )} a^{5} + 2240 \, {\left (3 \, \tan \left (d x + c\right )^{5} + 10 \, \tan \left (d x + c\right )^{3} + 15 \, \tan \left (d x + c\right )\right )} a^{5} + 5600 \, {\left (\tan \left (d x + c\right )^{3} + 3 \, \tan \left (d x + c\right )\right )} a^{5} - 175 \, a^{5} {\left (\frac {2 \, {\left (15 \, \sin \left (d x + c\right )^{5} - 40 \, \sin \left (d x + c\right )^{3} + 33 \, \sin \left (d x + c\right )\right )}}{\sin \left (d x + c\right )^{6} - 3 \, \sin \left (d x + c\right )^{4} + 3 \, \sin \left (d x + c\right )^{2} - 1} - 15 \, \log \left (\sin \left (d x + c\right ) + 1\right ) + 15 \, \log \left (\sin \left (d x + c\right ) - 1\right )\right )} - 2100 \, a^{5} {\left (\frac {2 \, {\left (3 \, \sin \left (d x + c\right )^{3} - 5 \, \sin \left (d x + c\right )\right )}}{\sin \left (d x + c\right )^{4} - 2 \, \sin \left (d x + c\right )^{2} + 1} - 3 \, \log \left (\sin \left (d x + c\right ) + 1\right ) + 3 \, \log \left (\sin \left (d x + c\right ) - 1\right )\right )} - 840 \, a^{5} {\left (\frac {2 \, \sin \left (d x + c\right )}{\sin \left (d x + c\right )^{2} - 1} - \log \left (\sin \left (d x + c\right ) + 1\right ) + \log \left (\sin \left (d x + c\right ) - 1\right )\right )}}{3360 \, d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 2.65, size = 150, normalized size = 0.96 \begin {gather*} \frac {9765 \, a^{5} \cos \left (d x + c\right )^{7} \log \left (\sin \left (d x + c\right ) + 1\right ) - 9765 \, a^{5} \cos \left (d x + c\right )^{7} \log \left (-\sin \left (d x + c\right ) + 1\right ) + 2 \, {\left (15328 \, a^{5} \cos \left (d x + c\right )^{6} + 9765 \, a^{5} \cos \left (d x + c\right )^{5} + 7664 \, a^{5} \cos \left (d x + c\right )^{4} + 5950 \, a^{5} \cos \left (d x + c\right )^{3} + 3648 \, a^{5} \cos \left (d x + c\right )^{2} + 1400 \, a^{5} \cos \left (d x + c\right ) + 240 \, a^{5}\right )} \sin \left (d x + c\right )}{3360 \, d \cos \left (d x + c\right )^{7}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} a^{5} \left (\int \sec ^{3}{\left (c + d x \right )}\, dx + \int 5 \sec ^{4}{\left (c + d x \right )}\, dx + \int 10 \sec ^{5}{\left (c + d x \right )}\, dx + \int 10 \sec ^{6}{\left (c + d x \right )}\, dx + \int 5 \sec ^{7}{\left (c + d x \right )}\, dx + \int \sec ^{8}{\left (c + d x \right )}\, dx\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.57, size = 170, normalized size = 1.09 \begin {gather*} \frac {9765 \, a^{5} \log \left ({\left | \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) + 1 \right |}\right ) - 9765 \, a^{5} \log \left ({\left | \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - 1 \right |}\right ) - \frac {2 \, {\left (9765 \, a^{5} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{13} - 65100 \, a^{5} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{11} + 184233 \, a^{5} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{9} - 285696 \, a^{5} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{7} + 260183 \, a^{5} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} - 132020 \, a^{5} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} + 43995 \, a^{5} \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )}}{{\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - 1\right )}^{7}}}{1680 \, d} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 4.84, size = 228, normalized size = 1.46 \begin {gather*} \frac {93\,a^5\,\mathrm {atanh}\left (\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\right )}{8\,d}-\frac {\frac {93\,a^5\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^{13}}{8}-\frac {155\,a^5\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^{11}}{2}+\frac {8773\,a^5\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^9}{40}-\frac {11904\,a^5\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^7}{35}+\frac {37169\,a^5\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^5}{120}-\frac {943\,a^5\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^3}{6}+\frac {419\,a^5\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}{8}}{d\,\left ({\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^{14}-7\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^{12}+21\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^{10}-35\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^8+35\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^6-21\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^4+7\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2-1\right )} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________